# _*_ coding:utf-8 _*_
# at:2024-07-24
# author:zizle

import json
with open('ume_user.json', 'r', encoding='utf8') as f:
    lines = f.readlines()

with open('ume_user_aliyun.json', 'a+', encoding='utf8') as f2:
    for ln in lines:
        d = json.loads(ln)
        js = {
            '_id': {'$oid': d['_id']},
        }
        del d['_id']
        js.update(d)

        f2.write(json.dumps(js) + '\n')
